from selenium import webdriver
import time

from selenium.webdriver.common.action_chains import ActionChains
from selenium.webdriver.common.keys import Keys
from selenium.webdriver.common.by import By



drivr= webdriver.Edge()
drivr.maximize_window()

drivr.get('https://mail.163.com/')
time.sleep(20)

f=drivr.find_element(By.XPATH,'//iframe[starts-with(@id,"x-URS-iframe174340")]')
drivr.switch_to.frame(f)
time.sleep(5)

drivr.find_element(By.NAME,'email').send_keys('17733058407')
time.sleep(5)

drivr.find_element(By.NAME,'password').send_keys('LCf10140910')
time.sleep(5)

drivr.find_element(By.XPATH,'//*[@id="dologin"]').click()
time.sleep(5)


# 1.点击写信
# 2.输入收件人账号（QQ）
# 3.输入邮件主题
# 4.输入邮件内容
# 5.点击发 送